(function (global, factory) {
    typeof exports === 'object' && typeof module !== 'undefined'
        ? (module.exports = factory())
        : typeof define === 'function' && define.amd
        ? define(factory)
        : ((global = global || self), (global.tpUtils = factory()));
})(this, function () {
    const virtualPathReg = /^(\/[\w, \d, \-, _, \/]+?)\/webroot\//;
    const matchVirtualPathResult = location.pathname.match(virtualPathReg);
    let urlVirtualPath = matchVirtualPathResult ? matchVirtualPathResult[1] : '';
    let virtualPath = urlVirtualPath;

    try {
        virtualPath = tpSaaSCore.getUserInfo().virtualPath || virtualPath;
    } catch (e) {}
    const BASE_API = virtualPath + '/api_server';
    const isDef = (val) => val !== undefined && val !== null;

    function request(api, param, method) {
        method = method || 'post';
        return new Promise((resolve, reject) => {
            tpHttp[method](
                this,
                api,
                {
                    param: JSON.stringify(param || {}),
                },
                (data, code, message) => {
                    const res = {
                        data,
                        code,
                        message,
                    };
                    if (code == 0) {
                        resolve(data);
                    } else {
                        reject(res);
                    }
                }
            );
        });
    }

    // 接口请求
    function commonRequest(api, param, method) {
        method = method || 'post';
        return new Promise((resolve, reject) => {
            tpHttp[method](this, api, param, (data, code, message) => {
                const res = {
                    data,
                    code,
                    message,
                };
                if (code == 0) {
                    resolve(data);
                } else {
                    reject(res);
                }
            });
        });
    }

    let userDetails = {};
    try {
        userDetails = GLOBAL_CONFIG.userDetails();
    } catch (e) {
        userDetails = {
            unitId: 1616,
        };
    }

    function requestApi(api_id, key) {
        const param = {
            apiAlias: api_id,
            key: Object.assign(
                {
                    where: '',
                    orderBy: '',
                },
                key
            ),
        };
        return request(
            tpSaaSCore.getUserInfo().virtualPath +
                `/api_server/api?action=com.top.local.xsys.common.callDcApiByAlias`,
            param
        );
    }

    function objToParams(obj) {
        return Object.keys(obj)
            .map(function (key) {
                return ''.concat(encodeURIComponent(key), '=').concat(encodeURIComponent(obj[key]));
            })
            .join('&');
    }

    function requestModel(key) {
        const param = {
            api_id: 102,
            unit_id: userDetails.unitId,
            key: Object.assign(
                {
                    unitId: userDetails.unitId,
                    modelId: '',
                    page: 1,
                    size: 9999,
                    where: '',
                    orderBy: '',
                },
                key
            ),
        };
        return request(`ycc-system/rpcIotApi?model_id=${key.modelId}`, param);
    }

    function requestParkApi(api_id, key) {
        const param = {
            api_id: api_id,
            key: key,
        };
        return request(`fl-system/rpcIotApiDev`, param);
    }

    function parseTime(time, cFormat) {
        if (arguments.length === 0) {
            return null;
        }
        const format = cFormat || '{y}-{m}-{d} {h}:{i}:{s}';
        const date = getDateObj(time);
        const formatObj = {
            y: date.getFullYear(),
            m: date.getMonth() + 1,
            d: date.getDate(),
            h: date.getHours(),
            i: date.getMinutes(),
            s: date.getSeconds(),
            a: date.getDay(),
        };
        const timeStr = format.replace(/{(y|m|d|h|i|s|a)+}/g, (result, key) => {
            let value = formatObj[key];
            // Note: getDay() returns 0 on Sunday
            if (key === 'a') {
                return ['日', '一', '二', '三', '四', '五', '六'][value];
            }
            if (result.length > 0 && value < 10) {
                value = '0' + value;
            }
            return value || 0;
        });
        return timeStr;
    }

    function getDateObj(time) {
        let date;
        if (typeof time === 'object') {
            date = time;
        } else {
            if (typeof time === 'string') {
                if (/^[0-9]+$/.test(time)) {
                    time = parseInt(time);
                } else {
                    time = time.replace(/\-/g, '/');
                }
            }
            if (typeof time === 'number' && time.toString().length === 10) {
                time = time * 1000;
            }
            date = new Date(time);
        }
        return date;
    }

    /**
     * 获取两个日期之间的日期
     * @param start
     * @param end
     * @param type 1：不包含起始日期，包含结束日期 2：包含起始日期，不包含结束日期 3：包含起始日期，包含结束日期
     * @returns {date[]}
     */
    function getBetweenDateStr(start, end, type = 1) {
        const startTime = getDateObj(start);
        const endTime = getDateObj(end);
        const arr = [];
        if (type === 1) {
            while (endTime.getTime() - startTime.getTime() > 0) {
                startTime.setDate(startTime.getDate() + 1);
                arr.push(parseTime(startTime, '{y}-{m}-{d}'));
            }
        } else if (type === 2) {
            while (endTime.getTime() - startTime.getTime() > 0) {
                arr.push(parseTime(startTime, '{y}-{m}-{d}'));
                startTime.setDate(startTime.getDate() + 1);
            }
        } else if (type === 3) {
            while (endTime.getTime() - startTime.getTime() >= 0) {
                arr.push(parseTime(startTime, '{y}-{m}-{d}'));
                startTime.setDate(startTime.getDate() + 1);
            }
        }
        return arr;
    }

    /**
     * @desc 函数防抖
     * @param func 函数
     * @param wait 延迟执行毫秒数
     * @param immediate true 表立即执行，false 表非立即执行
     */
    function debounce(func, wait, immediate) {
        let timeout, result;

        const debounced = function () {
            const context = this;
            const args = arguments;

            if (timeout) {
                clearTimeout(timeout);
            }
            if (immediate) {
                // 如果已经执行过，不再执行
                const callNow = !timeout;
                timeout = setTimeout(function () {
                    timeout = null;
                }, wait);
                if (callNow) {
                    result = func.apply(context, args);
                }
            } else {
                timeout = setTimeout(function () {
                    func.apply(context, args);
                }, wait);
            }

            return result;
        };

        debounced.cancel = function () {
            clearTimeout(timeout);
            timeout = null;
        };

        return debounced;
    }

    function deepMerge(target, merged) {
        for (const key in merged) {
            if (target[key] && typeof target[key] === 'object') {
                deepMerge(target[key], merged[key]);

                continue;
            }

            if (typeof merged[key] === 'object') {
                target[key] = deepClone(merged[key], true);

                continue;
            }

            target[key] = merged[key];
        }

        return target;
    }

    function deepClone(object, recursion = false) {
        if (!object) return object;

        const { parse, stringify } = JSON;

        if (!recursion) return parse(stringify(object));

        const clonedObj = object instanceof Array ? [] : {};

        if (object && typeof object === 'object') {
            for (const key in object) {
                if (object.hasOwnProperty(key)) {
                    /* eslint-disable-line */
                    if (object[key] && typeof object[key] === 'object') {
                        clonedObj[key] = deepClone(object[key], true);
                    } else {
                        clonedObj[key] = object[key];
                    }
                }
            }
        }

        return clonedObj;
    }

    // 判断是否为空
    function validatenull(val) {
        if (typeof val === 'boolean') {
            return false;
        }
        if (val instanceof Array) {
            if (val.length === 0) return true;
        } else if (val instanceof Object) {
            if (JSON.stringify(val) === '{}') return true;
        } else {
            if (
                val === 'null' ||
                val == null ||
                val === 'undefined' ||
                val === undefined ||
                val === ''
            )
                return true;
            return false;
        }
        return false;
    }

    // 数字
    function isNumber(value) {
        if (isNaN(value)) {
            return false;
        }
        return typeof +value === 'number';
    }

    function toNumber(value, fractionDigits = 2) {
        return isNumber(value) ? Number(value).toFixed(fractionDigits) - 0 : 0;
    }

    function observerDomResize(dom, callback) {
        const MutationObserver =
            window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver;

        const observer = new MutationObserver(callback);

        observer.observe(dom, {
            attributes: true,
            attributeFilter: ['style'],
            attributeOldValue: true,
        });

        return observer;
    }

    function formatNumber(number) {
        var arr = (number + '').split('.');
        var int = arr[0].split('');
        var fraction = arr[1] || '';
        var r = '';
        var len = int.length;
        int.reverse().forEach(function (v, i) {
            if (i !== 0 && i % 3 === 0) {
                r = v + ',' + r;
            } else {
                r = v + r;
            }
        });
        return r + (!!fraction ? '.' + fraction : '');
    }

    function pieChartAnimation(chart, data, seriesIndex) {
        if (data.length <= 1) return;
        seriesIndex = seriesIndex || 0;
        let index = 0;
        let timer = null;

        function highlightChange(index) {
            for (let i = 0; i < data.length; i++) {
                if (index === i) {
                    chart.dispatchAction({
                        type: 'highlight',
                        seriesIndex: seriesIndex,
                        dataIndex: i,
                    });
                } else {
                    chart.dispatchAction({
                        type: 'downplay',
                        seriesIndex: seriesIndex,
                        dataIndex: i,
                    });
                }
            }
        }

        function startAnimation() {
            stopAnimation();
            timer = setInterval(() => {
                index++;
                if (index === data.length) {
                    index = 0;
                }
                highlightChange(index);
            }, 2000);
        }

        function stopAnimation() {
            clearInterval(timer);
        }

        highlightChange(0);
        startAnimation();
        chart.on('mouseover', (e) => {
            index = e.dataIndex;
            stopAnimation();
            highlightChange(index);
        });
        chart.on('mouseout', (e) => {
            index = e.dataIndex;
            startAnimation();
            // highlightChange(index);
        });
        chart.stopAnimation = stopAnimation;
    }

    // 换算方法
    function getResizePx(px, defaultWidth = 1920) {
        const width = document.documentElement.clientWidth;
        return px * (width / defaultWidth);
    }

    function getVerticalResizePx(px, defaultWidth = 1080) {
        const width = document.documentElement.clientHeight;
        return px * (width / defaultWidth);
    }

    function getDataMapping(data, key) {
        return data.reduce((pre, cur) => {
            if (pre[cur[key]]) {
                pre[cur[key]].push(cur);
            } else {
                pre[cur[key]] = [cur];
            }
            return pre;
        }, {});
    }

    function getRandomInt(min, max) {
        min = Math.ceil(min);
        max = Math.floor(max);
        return Math.floor(Math.random() * (max - min)) + min; // 不含最大值，含最小值
    }

    function getRandomIntInclusive(min, max) {
        min = Math.ceil(min);
        max = Math.floor(max);
        return Math.floor(Math.random() * (max - min + 1)) + min; // 含最大值，含最小值
    }

    // 获取图形中心坐标
    function calculateCenter(lnglatarr) {
        var total = lnglatarr.length;
        var X = 0;
        var Y = 0;
        var Z = 0;

        lnglatarr
            .map((arr) => ({
                lng: arr[0],
                lat: arr[1],
            }))
            .forEach(function (lnglat) {
                var lng = (lnglat.lng * Math.PI) / 180;
                var lat = (lnglat.lat * Math.PI) / 180;
                var x, y, z;
                x = Math.cos(lat) * Math.cos(lng);
                y = Math.cos(lat) * Math.sin(lng);
                z = Math.sin(lat);
                X += x;
                Y += y;
                Z += z;
            });

        X = X / total;
        Y = Y / total;
        Z = Z / total;

        var Lng = Math.atan2(Y, X);
        var Hyp = Math.sqrt(X * X + Y * Y);
        var Lat = Math.atan2(Z, Hyp);

        // return new AMap.LngLat(Lng * 180 / Math.PI, Lat * 180 / Math.PI);
        return [(Lng * 180) / Math.PI, (Lat * 180) / Math.PI];
    }

    function getRandomColor(min = 0, max = 255) {
        return `rgb(${getRandomIntInclusive(
            min,
            max
        )}, ${getRandomIntInclusive(min, max)}, ${getRandomIntInclusive(min, max)})`;
    }

    /**
     * 十六进制颜色转换为带透明度的颜色
     * @param _color 十六进制颜色
     * @param _opactity 透明度
     * @returns {string} rgba
     */
    function hexToRGBA(_color, _opacity) {
        let sColor = _color.toLowerCase();
        // 十六进制颜色值的正则表达式
        const reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
        // 如果是16进制颜色
        if (sColor && reg.test(sColor)) {
            if (sColor.length === 4) {
                let sColorNew = '#';
                for (let i = 1; i < 4; i += 1) {
                    sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1));
                }
                sColor = sColorNew;
            }
            // 处理六位的颜色值
            const sColorChange = [];
            for (let i = 1; i < 7; i += 2) {
                sColorChange.push(parseInt('0x' + sColor.slice(i, i + 2)));
            }
            return 'rgba(' + sColorChange.join(',') + ',' + _opacity + ')';
        }
        return sColor;
    }

    //换算方法
    function nowSize(val, initWidth = 1920) {
        let nowClientWidth = document.documentElement.clientWidth;
        return val * (nowClientWidth / initWidth);
    }

    function getNavData({ items = [], activeCode = '', activeChildCode = '' }) {
        const navList = [];
        let childNavList = [];
        items.forEach((item) => {
            if (item.code == activeCode) {
                item.active = true;
                childNavList = item.children || [];
            }
            const children = item.children;
            let href = item.href || 'javascript:;';
            let target = item.target || '_self';
            if (Array.isArray(children) && children.length) {
                let matchChild = null;
                children.forEach((child) => {
                    child.href = this.$aHrefHandle(
                        child.href || '' /* { code: item.code, childCode: child.code }*/
                    );
                    if (child.code == activeChildCode) {
                        matchChild = child;
                        // child.active = true;
                    }
                });
                if (!matchChild) {
                    matchChild = children[0];
                }
                matchChild.active = true;
                if (item.code != activeCode) {
                    href = this.$aHrefHandle(
                        matchChild.href || '' /* { code: item.code, childCode: matchChild.code }*/
                    );
                    target = matchChild.target || '';
                }
            } else {
                if (item.code != activeCode) {
                    href = this.$aHrefHandle(item.href || '' /* { code: item.code }*/);
                    target = item.target || '';
                }
            }
            navList.push(
                Object.assign({}, item, {
                    href,
                    target,
                })
            );
        });
        return {
            navList,
            childNavList,
        };
    }

    // 获取图形中心坐标
    function calculateCenter(lnglatarr) {
        var total = lnglatarr.length;
        var X = 0;
        var Y = 0;
        var Z = 0;

        lnglatarr
            .map((arr) => ({
                lng: arr[0],
                lat: arr[1],
            }))
            .forEach(function (lnglat) {
                var lng = (lnglat.lng * Math.PI) / 180;
                var lat = (lnglat.lat * Math.PI) / 180;
                var x, y, z;
                x = Math.cos(lat) * Math.cos(lng);
                y = Math.cos(lat) * Math.sin(lng);
                z = Math.sin(lat);
                X += x;
                Y += y;
                Z += z;
            });

        X = X / total;
        Y = Y / total;
        Z = Z / total;

        var Lng = Math.atan2(Y, X);
        var Hyp = Math.sqrt(X * X + Y * Y);
        var Lat = Math.atan2(Z, Hyp);

        // return new AMap.LngLat(Lng * 180 / Math.PI, Lat * 180 / Math.PI);
        return [(Lng * 180) / Math.PI, (Lat * 180) / Math.PI];
    }

    const cubic = (value) => Math.pow(value, 3);
    const easeInOutCubic = (value) =>
        value < 0.5 ? cubic(value * 2) / 2 : 1 - cubic((1 - value) * 2) / 2;
    const scrollToTop = (el) => {
        const beginTime = Date.now();
        const beginValue = el.scrollTop;
        const rAF = window.requestAnimationFrame || ((func) => setTimeout(func, 16));
        const frameFunc = () => {
            const progress = (Date.now() - beginTime) / 500;
            if (progress < 1) {
                el.scrollTop = beginValue * (1 - easeInOutCubic(progress));
                rAF(frameFunc);
            } else {
                el.scrollTop = 0;
            }
        };
        rAF(frameFunc);
    };
    /* 按指定类型对数组进行分组 */
    function sortDataList(data, type) {
        let c = [];
        let d = {};
        if (data.length > 0) {
            data.map((element) => {
                if (!d[element[type]]) {
                    // 按照type分类
                    c.push({
                        type: element[type],
                        list: [element],
                    });
                    d[element[type]] = element;
                } else {
                    c.map((ele) => {
                        if (ele.type == element[type]) {
                            ele.list.push(element);
                        }
                    });
                }
            });
        }

        return c;
    }
    /* 保留指定小数位数 */
    function toNumFixed(num, decimal) {
        num = num.toString();
        let index = num.indexOf('.');
        if (index !== -1) {
            num = num.substring(0, decimal + index + 1);
            return parseFloat(num).toFixed(decimal);
        } else {
            num = num.substring(0);
            return parseFloat(num);
        }
    }

    function getFormatterText(text, number, separator) {
        number = number || 3;
        separator = separator || '\n'; // 或 <br>
        var newParamsName = ''; // 返回文字格式
        var paramsNameNumber = text.length; // 获取显示文字长度
        var rowNumber = Math.ceil(paramsNameNumber / number); // 最多能显示几行
        if (paramsNameNumber > number) {
            // 如果长度大于每行最多显示的字数
            for (var p = 0; p < rowNumber; p++) {
                // 循环次数就是行数
                var tempStr = ''; // 每次截取的字符
                var start = p * number; // 截取的起点
                var end = start + number; // 截取的终点
                if (p == rowNumber - 1) {
                    // 最后一行就不换行了
                    tempStr = text.substring(start);
                } else {
                    tempStr = text.substring(start, end) + separator;
                }
                newParamsName += tempStr; // 拼接字符串
            }
        } else {
            newParamsName = text; // 如果小于每行最多显示的字数就返回原来的字符串
        }
        return newParamsName;
    }

    //计算两个时间之间间隔几天
    function computeDataBetween(date1, date2) {
        //'2022-01-01' 日期格式
        const timeStr1 = new Date(date1);
        const timeStr2 = new Date(date2);

        // 计算时间戳差值（单位：毫秒）
        const timestampDiff = Math.abs(timeStr2.getTime() - timeStr1.getTime());

        // 将时间戳差值转换为天数
        const daysDiff = Math.ceil(timestampDiff / (1000 * 60 * 60 * 24));

        return daysDiff;
    }

    //计算一个时间是否在2个时间之间
    function dateBetweenType(targetDate, dateArray) {
        let timeNumArray = dateArray.map((item) => {
            return new Date(item);
        });
        const targetTimeDate = new Date(targetDate);
        let index = '';
        let flag = false;
        timeNumArray.forEach((item, i) => {
            if (!flag && targetTimeDate < item) {
                index = i;
                flag = true;
            }
        });
        return index;
    }
    //转换为base64位编码
    function toBase64(arr) {
        const json = JSON.stringify(arr); // 将对象数组转换为 JSON 字符串
        const utf8 = unescape(encodeURIComponent(json)); // 将 JSON 字符串转换为 UTF-8 格式
        let latin1 = '';
        for (let i = 0; i < utf8.length; i++) {
            const charCode = utf8.charCodeAt(i);
            if (charCode < 256) {
                latin1 += String.fromCharCode(charCode);
            }
        }
        const base64 = btoa(latin1);
        return base64;
    }

    //输入开始日期和间隔天数数组，依次输出日期节点
    function calculateEndDate(startDate, daysArray) {
        let inputDate = new Date(startDate);
        let resultDates = [];

        for (let i = 0; i < daysArray.length; i++) {
            let daysToAdd = daysArray[i];

            let resultDate = new Date(inputDate.getTime() + daysToAdd * 24 * 60 * 60 * 1000);

            let day = resultDate.getDate();
            let month = resultDate.getMonth() + 1;
            let year = resultDate.getFullYear();

            resultDates.push(
                `${year}-${month < 10 ? '0' : ''}${month}-${day < 10 ? '0' : ''}${day}`
            );

            // 修改输入日期为当前计算出的结果日期，以便于下一次循环继续累加天数
            inputDate = resultDate;
        }
        resultDates.unshift(startDate);
        return resultDates;
    }
    //计算一个时间是否大于另一个时间
    function compareTwoDate(date1, date2) {
        let time1 = new Date(date1);
        let time2 = new Date(date2);
        if (time1.getTime() > time2.getTime()) {
            return false;
        } else {
            return true;
        }
    }

    function formatTime(seconds) {
        const hours = Math.floor(seconds / 3600);
        seconds %= 3600;
        const minutes = Math.floor(seconds / 60);
        seconds %= 60;
        console.log(minutes);
        console.log(seconds);
        return `${
            hours > 0 ? hours + ':' : ''
        }${String(minutes).padStart(2, '0')}:${String(Math.round(seconds)).padStart(2, '0')}`;
    }
    //获取当前日期 2023-05-30
    function getDate(spli, type) {
        let date = new Date();
        let y = date.getFullYear();
        let M = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1;
        let d = date.getDate() < 10 ? '0' + date.getDate() : date.getDate();
        if (type) {
            return y + '年' + M + '月' + d + '日';
        } else {
            return y + spli + M + spli + d;
        }
    }
    //获取目标天数  如输入 2023-04-14 10 10  输出2023-04-04 2023-04-24
    function getPurpleDate(now, daybefore, dayafter) {
        let date = new Date(now);
        const timestamp1 = date.getTime() - daybefore * 24 * 60 * 60 * 1000;
        const timestamp2 = date.getTime() + dayafter * 24 * 60 * 60 * 1000;

        return [
            new Date(timestamp1).toISOString().substring(0, 10),
            new Date(timestamp2).toISOString().substring(0, 10),
        ];
    }
    //获取是星期几
    function getDayOfWeek(day) {
        const daysOfWeek = ['星期日', '星期一', '星期二', '星期三', '星期四', '星期五', '星期六'];
        let today;
        let dayOfWeek;
        if (day) {
            today = new Date(day);
            dayOfWeek = today.getDay();
        } else {
            today = new Date();
            dayOfWeek = today.getDay();
        }

        return daysOfWeek[dayOfWeek];
    }

    /**
     * 节流原理：在一定时间内，只能触发一次
     *
     * @param {Function} func 要执行的回调函数
     * @param {Number} wait 延时的时间
     * @param {Boolean} immediate 是否立即执行
     * @return null
     */
    function throttle(func, wait = 500, immediate = true) {
        let timer, flag;
        return function () {
            const context = this;
            const args = arguments;

            if (immediate) {
                if (!flag) {
                    flag = true;
                    // 如果是立即执行，则在wait毫秒内开始时执行
                    typeof func === 'function' && func.apply(context, args);
                    timer = setTimeout(() => {
                        flag = false;
                    }, wait);
                }
            } else if (!flag) {
                flag = true;
                // 如果是非立即执行，则在wait毫秒内的结束处执行
                timer = setTimeout(() => {
                    flag = false;
                    typeof func === 'function' && func.apply(context, args);
                }, wait);
            }
        };
    }

    function handleServerExport(action, param, method = 'post') {
        const formDom = document.createElement('form');
        formDom.style.display = 'none';
        formDom.action = action;
        formDom.target = '';
        formDom.method = method;
        document.body.appendChild(formDom);
        const inputDom = document.createElement('input');
        inputDom.name = 'param';
        inputDom.value = JSON.stringify(param);
        formDom.appendChild(inputDom);
        formDom.submit();
        document.body.removeChild(formDom);
    }

    function getDataModelLabel({ items, targetValue, labelKey, valueKey }) {
        labelKey = labelKey || 'label';
        valueKey = valueKey || 'value';
        const [item = {}] = items.filter((t) => t[valueKey] == targetValue);
        return item[labelKey] || '';
    }

    //判断一串数字是否是连续的
    const isContinuityNum = (num) => {
        let array = [];
        if (num instanceof Array) {
            array = [...num];
        } else {
            array = Array.from(num.toString()); //转换为数组
        }

        let i = array[0];
        let isContinuation = true;
        for (let e in array) {
            if (array[e] != i) {
                isContinuation = false;
                break;
            }
            i++;
        }
        return isContinuation;
    };
    function getPercentageValue(value, total, fractionDigits = 2) {
        if (value == 0 || !value) return 0;
        let percentage = tpUtils.toNumber((value / total) * 100, fractionDigits);
        if (fractionDigits == 0) {
            percentage = percentage == 0 ? '< 1' : percentage;
        } else {
            percentage =
                percentage == 0 ? '< ' + '0.' + '1'.padStart(fractionDigits, '0') : percentage;
        }
        return percentage;
    }
    return {
        getPercentageValue,
        getDayOfWeek,
        getPurpleDate,
        getDate,
        BASE_API,
        formatTime,
        compareTwoDate,
        calculateEndDate,
        toBase64,
        dateBetweenType,
        computeDataBetween,
        isDef,
        request,
        commonRequest,
        requestApi,
        requestModel,
        parseTime,
        getDateObj,
        getBetweenDateStr,
        debounce,
        deepMerge,
        deepClone,
        validatenull,
        isNumber,
        toNumber,
        formatNumber,
        observerDomResize,
        pieChartAnimation,
        getResizePx,
        getVerticalResizePx,
        getDataMapping,
        getRandomInt,
        getRandomIntInclusive,
        getRandomColor,
        hexToRGBA,
        nowSize,
        // getYearOnYear,
        calculateCenter,
        scrollToTop,
        getFormatterText,
        sortDataList,
        toNumFixed,
        requestParkApi,
        objToParams,
        throttle,
        handleServerExport,
        getDataModelLabel,
        isContinuityNum,
    };
});
